-- GENERATED SPELL FOR [Unstable Voidwraith] --


function spell0_18869(pUnit, Event) --@Coalesce,Self--
pUnit:FullCastSpellOnTarget(34302,pUnit)
pUnit:RegisterEvent('Sorts_18869', 1500, 1)
end

function spell1_18869(pUnit, Event) --@Unstable Rift,n/a--
pUnit:FullCastSpellOnTarget(36463,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18869', 10342, 1)
end

function Sorts_18869(pUnit, Event)
local choix_sorts_18869 = math.random(0, 1)
if choix_sorts_18869 == 0 then
pUnit:RegisterEvent('spell0_18869', 1, 1)
end
if choix_sorts_18869 == 1 then
pUnit:RegisterEvent('spell1_18869', 1, 1)
end
end

function mob18869_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_18869', math.random(1500, 3000), 1)
end

function mob18869_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob18869_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob18869_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(18869, 1, 'mob18869_Action')
RegisterUnitEvent(18869, 2, 'mob18869_Leave')
RegisterUnitEvent(18869, 3, 'mob18869_Kill')
RegisterUnitEvent(18869, 4, 'mob18869_Die')
